package com.njlime.sys.service;

import com.njlime.sys.entities.Log;
import com.njlime.sys.repository.LogDao;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import javax.annotation.Resource;

/**
 * Created by Dean on 2017-7-27.
 */
@Service
@Transactional(readOnly = true)
public class LogService {

    @Resource
    private LogDao logDao;

    /**
     * 添加日志
     * @param log
     */
    @Transactional(readOnly = false)
    public void addLog(Log log){
        logDao.save(log);
    }
}
